package com.glgc.projecti.common;

import java.util.List;

public class CommonUtils {

	public static boolean isEmpty(String str) {
		if (str == null || str.length() == 0)
			return true;
		return false;
	}

	public static boolean isNotEmpty(String str) {
		return str != null && str.length() > 0;
	}

	public static boolean isEquals(String s1, String s2) {
		if (s1 == null && s2 == null)
			return true;
		if (s1 == null || s2 == null)
			return false;
		return s1.equals(s2);
	}
	
	public static boolean isListEmpty(List<?> list) {
		if (list == null) {
			return true;
		} else {
			if (list.size() == 0) {
				return true;
			}
		}
		return false;
	}
	
	public static boolean isListNotEmtpy(List<?> list) {
		return !(isListEmpty(list));
	}
}
